package com.fenqing.leetcode.code.t1800_1900;

import com.fenqing.annotations.Execute;
import com.fenqing.core.Topic;

public class Topic1832 extends Topic {

    @Execute
    public boolean checkIfPangram(String sentence) {
        boolean[] flags = new boolean[26];
        char off = 'a';
        char[] chars = sentence.toCharArray();
        int sum = 0;
        for (char ch : chars) {
            int idx = ch - off;
            if (!flags[idx]) {
                sum++;
                flags[idx] = true;
            }
        }
        return sum == 26;
    }

    public static void main(String[] args) {
        boolean flag = new Topic1832().run("thequickbrownfoxjumpsoverthelazydog");
        System.out.println(flag);
    }

}
